package com.tanhua.server.service;

import com.tanhua.dubbo.api.QuestionApi;
import com.tanhua.model.domain.Question;
import org.apache.dubbo.config.annotation.DubboReference;
import org.springframework.stereotype.Service;

@Service
public class QuestionService {
    @DubboReference
    private QuestionApi questionApi;

    public String findByUserId(Long userId) {
        Question question = questionApi.findById(userId);
       if(question==null){
           return "你喜欢apex吗";
       }
          return question.getTxt();
    }

}
